package org.guangzhou.notepad;

import org.guangzhou.notepad.activity.LoginActivity;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;

public class LoadActivity extends Activity {
	
	private String logTag = "LoadActivity--->";
	
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        
        setProgressBarVisibility(true);// 显示进度条（条状）
    	timerThread.start();
		
    }
    
    Thread timerThread = new Thread(){
  		public void run(){
  			Log.i(logTag, "timerThread star...");
  			try {
				Thread.sleep(1000);
	  			toLogin();
			} catch (InterruptedException e) {
				// TODO Auto-generated catch block
				e.printStackTrace();
			}
  		}
    };
    
    public void toLogin(){
    	Intent intent = new Intent(this, LoginActivity.class);
		this.startActivity(intent);
		finish();
    }
    
    
    
}